<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>Admin</title>
    <include file="layout/style"/>
</head>

<body>

<div id="wrapper">

    <!-- 导航文件 -->
    <include file="layout/menu"/>

    <!-- 页面 -->
    <div id="page-wrapper">
        <div class="row">
            <div class="col-lg-12">
                <h1 class="page-header">
                    修改密码
                </h1>
                <ol class="breadcrumb">
                    <li>
                        <i class="glyphicon glyphicon-home"></i> <a href="{:U('Admin/Index/index')}">后台首页</a>
                    </li>
                    <li class="active">
                        <i class="glyphicon glyphicon-file"></i> <a href="__ACTION__">当前页面</a>
                    </li>
                </ol>
                <hr>
            </div>
        </div>
        <div class="row">
            <div class="col-lg-3">
                <form method="post" onsubmit="return ckform();">
                    <div class="form-group">
                        <label>旧密码：</label>
                        <input type="password" class="form-control" name="old">
                    </div>
                    <div class="form-group">
                        <label>新密码：</label>
                        <input type="password" class="form-control" name="new">
                    </div>
                    <div class="form-group">
                        <label>确认密码：</label>
                        <input type="password" class="form-control" name="ck">
                    </div>
                    <button type="submit" class="btn btn-primary">保存</button>
                </form>
            </div>
        </div>
    </div>

</div>

</body>
</html>

<script>
    function ckform() {
        var ck = new Array(
                document.getElementsByName("old")[0],
                document.getElementsByName("new")[0],
                document.getElementsByName("ck")[0]
        );
        for (var i = 0; i < ck.length; i++) {
            if (!ck[i].value) {
                ck[i].focus();
                return false;
            }
        }

        return true;
    }
</script>